package com.ruibang.glass.produce.entity;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.alibaba.excel.annotation.write.style.ContentStyle;
import com.alibaba.excel.enums.poi.HorizontalAlignmentEnum;
import com.alibaba.excel.enums.poi.VerticalAlignmentEnum;
import com.alibaba.fastjson.annotation.JSONField;
import com.teaming.cloud.framework2.common.tools.LocalDateTimeStringConverter;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * @Author: songJinKang
 * @CreateTime: 2024-03-14  10:54
 * @Description: TODO
 * @Version: 1.0
 */
@Data
@ApiModel
@ContentStyle(horizontalAlignment = HorizontalAlignmentEnum.CENTER, verticalAlignment = VerticalAlignmentEnum.CENTER)
public class GlassBind {
    @ApiModelProperty("热端玻璃ID")
    @ExcelProperty(value = {"玻璃ID"}, index = 0)
    @ColumnWidth(18)
    private String glassId;

    @ApiModelProperty("冷端ID")
    @ExcelProperty(value = {"流水号"}, index = 1)
    @ColumnWidth(18)
    private String newId;

    @ApiModelProperty("上一次投入关联ID")
    @ExcelProperty(value = {"上一次投入关联ID"}, index = 2)
    @ColumnWidth(18)
    private String oldId;

    @ApiModelProperty("投入口")
    @ExcelProperty(value = {"投入口"}, index = 3)
    @ColumnWidth(10)
    private String port;

    @ApiModelProperty("横切时间")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    @ExcelProperty(value = {"横切时间"}, index = 4, converter = LocalDateTimeStringConverter.class)
    @ColumnWidth(18)
    private LocalDateTime stationStartTime;

    @ApiModelProperty("投入时间")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    @ExcelProperty(value = {"投入时间"}, index = 5, converter = LocalDateTimeStringConverter.class)
    @ColumnWidth(18)
    private LocalDateTime feedTime;

    @ApiModelProperty("投入类型:1直投，0返投")
    @ColumnWidth(10)
    @ExcelProperty(value = {"投入类型(1:直投，0:返投)"}, index = 6)
    private String type;

    @ExcelIgnore
    private String createTime;
}
